package com.settlement.system.service;

import com.settlement.system.common.exception.ServiceException;
import com.settlement.system.mapper.security.userdetails.SysUserDetails;
import com.settlement.system.model.entity.common.SystemUser;
import com.settlement.system.model.entity.common.TblOrderAuditBill;
import com.settlement.system.model.entity.common.TblOrderAuditBillDtl;
import com.settlement.system.reply.ObjectDataResponse;
import jakarta.servlet.http.HttpServletRequest;
import org.springframework.web.multipart.MultipartFile;

import java.util.List;
import java.util.Map;

/**
 * 订单稽核单据明细表 服务类
 *
 * @author 小船
 * @since 2020-10-21
 */

public interface ITblOrderAuditBillDtlService extends IBaseService {

    /**
     * selectRoleStatus
     *
     * @param params
     * @return
     * @throws ServiceException
     */
    List<TblOrderAuditBillDtl> selectRoleStatus(Map<String, Object> params) throws ServiceException;

    /**
     * insertDtl
     *
     * @param bill
     * @param currentDtl
     * @throws ServiceException
     */
    void insertDtl(TblOrderAuditBill bill, TblOrderAuditBillDtl currentDtl) throws ServiceException;

    /**
     * selectLastSecond
     *
     * @param params
     * @return
     * @throws ServiceException
     */
    List<TblOrderAuditBillDtl> selectLastSecond(Map<String, Object> params) throws ServiceException;

    /**
     * updateBillStatus
     *
     * @param user
     * @param billNo
     * @throws ServiceException
     */
    void updateBillStatus(SysUserDetails user, String billNo) throws ServiceException;

    /**
     * 批量处理订单稽核单据
     *
     * @param tblOrderAuditBillDtl
     * @return
     * @throws ServiceException
     */
    Map<String, Object> batchSaveDtl(TblOrderAuditBillDtl tblOrderAuditBillDtl) throws ServiceException;

    /**
     * importFile
     *
     * @param file
     * @param request
     * @return
     */
    ObjectDataResponse importFile(MultipartFile file, HttpServletRequest request);
}

